package com.scott.observer.lesson01;

public class Client {
	
	public static void main(String[] args) {
		
		//定义2个观察者
		Observer o1 = new ConcreteObserver();
		Observer o2 = new ConcreteObserver();
		
		//定义1个目标对象
		ConcreteSubject subject = new ConcreteSubject();
		//注册观察者
		subject.add(o1);
		subject.add(o2);
		subject.setPrice(1100);
		
		
	}

}
